package chapter67;

public class TestGoods {

	public static void main(String[] args) {
		String type = null;
		Factory factory = new Factory();
		
		type = "computer";
		Goods goods = factory.produceGoods(type);
		goods.printPrice();
		
		type = "Tv";
		Goods goods1 = factory.produceGoods(type);
		goods1.printPrice();
		
		type = "foods";
		Goods goods2 = factory.produceGoods(type);
		goods2.printPrice();
		
		type = "冰箱";
		Goods goods3 = factory.produceGoods(type);
		goods3.printPrice();
		
	}
}
